package com.gxa.controller;


import com.gxa.common.base.RespResult;
import com.gxa.service.CommentsManagementService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import java.util.Map;

/*
 *@Author:那我也
 *@Date:2023/4/10-18:32
 *@Description:
 */
@RequestMapping("/commentsManagement")
@RestController
public class CommentsManagementController {

    @Autowired
    CommentsManagementService CommentsManagementServiceImpl;

    /*=========================1.服务评论查询（默认第一页，每页6条数据）=============================*/
    @PostMapping("/commentsFind")
    public RespResult commentsFind(@RequestBody Map<String,Object> map){
        return CommentsManagementServiceImpl.commentsFind(map);
    }

    /*==========================2.住宿评论（默认第一页，每页6条数据）=================================*/
    @PostMapping("/acCommentFind")
    public RespResult acCommentFind(@RequestBody Map<String,Object> map){
        return CommentsManagementServiceImpl.acCommentFind(map);
    }
    /*==========================3.上架与下架===================================*/
    @PostMapping("/upAndDown")
    public RespResult upAndDown(@RequestParam("AcId") Integer AcId){
        return CommentsManagementServiceImpl.upAndDown(AcId);
    }
}
